package com.zzyl.mapper;

import com.github.pagehelper.Page;
import com.zzyl.entity.NursingPlan;
import com.zzyl.entity.ProjectPlans;
import com.zzyl.vo.NursingPlanVo;
import com.zzyl.vo.ProjectPlanVo;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Mapper;

import java.util.List;

@Mapper
public interface NursingPlanMapper {

    List<NursingPlan> listAll();

    Page<NursingPlanVo> list(String name, Integer status);

    void addNursingPlan(NursingPlan plan);

    void addProjectPlans(List<ProjectPlans> projectPlansList);


    NursingPlanVo getNursingPlanById(Long id);

    List<ProjectPlanVo> getProjectPlans(Long id);

    void updateNursingPlanById(NursingPlan nursingPlan);


    @Delete("delete from nursing_project_plan where plan_id = #{planId}")
    void deleteProjectPlans(Long planId);

    void deleteById(Long id);

    void ban(Long id, Integer status);
}
